local skel = fk.CreateSkill {
  name = "emo__endian",
}

Fk:loadTranslationTable{
  ["emo__endian"] = "恩典",
  [":emo__endian"] = "出牌阶段，你可以重铸一张♣牌并横置一名角色。",

  ["#emo__endian"] = "恩典:重铸一张♣牌并横置一名角色",
}

skel:addEffect("active", {
  anim_type = "drawcard",
  prompt = "#emo__endian",
  card_num = 1,
  target_num = 1,
  card_filter = function (self, player, to_select, selected)
    return #selected == 0 and Fk:getCardById(to_select).suit == Card.Club
  end,
  target_filter = function (self, player, to_select, selected)
    return #selected == 0 and not to_select.chained
  end,
  can_use = function(self, player)
    return true
  end,
  on_use = function(self, room, effect)
    local player = effect.from
    local to = effect.tos[1]
    room:recastCard(effect.cards, player, skel.name)
    if not to.dead and not to.chained then
      to:setChainState(true)
    end
  end,
})

return skel
